#include "stdafx.h"
#include "CSamplerBase.h"

NAMESPACE_UI_BEGIN

CSolidSampler::CSolidSampler()
	: Color(0xFFFFFFFF)
{

}
CSolidSampler::CSolidSampler(uint_32 uiColor)
	: Color(uiColor)
{

}
CSolidSampler::~CSolidSampler()
{

}

SamplerTyle CSolidSampler::GetSampleType() const
{
	return SamplerTyleSolid;
}
uint_32 CSolidSampler::DoSample()
{
	return Color;
}
uint_32 CSolidSampler::DoSample(int_32 iX, int_32 iY)
{
	return Color;
}


CSolidBrush::CSolidBrush(uint_32 uiColor)
	: m_uiColor(uiColor)
{

}
CSolidBrush::~CSolidBrush()
{

}
SamplerTyle CSolidBrush::GetSampleType() const
{
	return SamplerTyleSolid;
}
uint_32 CSolidBrush::DoSample()
{
	return m_uiColor;
}
uint_32 CSolidBrush::DoSample(int_32 iX, int_32 iY)
{
	return m_uiColor;
}
void CSolidBrush::SetColor(uint_32 uiColor)
{
	m_uiColor = uiColor;
}

CPen::CPen(uint_32 uiColor, float_32 fWidth)
	: m_uiColor(uiColor), m_fWidth(fWidth) {}
CPen::~CPen() {}

SamplerTyle CPen::GetSampleType() const
{
	return SamplerTyleSolid;
}
uint_32 CPen::DoSample()
{
	return m_uiColor;
}
uint_32 CPen::DoSample(int_32 iX, int_32 iY)
{
	return m_uiColor;
}
void CPen::SetColor(uint_32 uiColor)
{
	m_uiColor = uiColor;
}
float_32 CPen::GetWidth() const
{
	return m_fWidth;
}
NAMESPACE_UI_END
